<template>
  <div>
    <div class="father">
      <div class="titles">
        <van-nav-bar title="聊天设置">
          <template #left>
            <van-icon name="arrow-left" size="18" @click="$router.go(-1)" />
          </template>
        </van-nav-bar>
      </div>
      <div class="bodys">
        <van-switch-cell
            v-model="checked"
            title="免打扰"
            size="22px"
            :active-color="$store.state.primary_color_1"
            inactive-color="#dcdee0"
          />
          <p v-show="!checked">以允许你的过的店铺主动发消息给你</p>
          <p v-show="checked">以禁止你的过的店铺主动发消息给你</p>
      </div>
    </div>
  </div>
</template>

<script>
  export default {
    data() {
      return {
        checked: true,
      }
    },
  }
</script>

<style lang="scss" scoped>
.father{
  height: 100vh;
  background-color: #f7f7f7;
  // 头部css样式
  .titles{
    .van-icon{
      border: 1px solid #888;
      border-radius: 50%;
      padding: 1px;
      color: #888;
      &:active{
        opacity: 0.4;
      }
    }
  }
  .bodys{
    margin-top: 6px;
    p{
      margin-top: 6px;
      padding-left: 1rem;
      font-size: 12px;
      color: #888;
    }
  }
}
</style>